﻿using System;

class Program
{
    static void Main()
    {
        string text = "We are living in a <upcase>yellow submarine</upcase>. We don't have <upcase>anything</upcase> else.";
        int start=0;
        int end=0;
        for (int i = 0; i < text.Length-8; i++)
        {
            if(text.Substring(i,8)=="<upcase>")
            {
               start=i+8;
               i=start;
            }
            if (text.Substring(i, 9) == "</upcase>")
            {
                end=i;
                int l=end-start;
                string upp=text.Substring(start,l).ToUpper();
                text=text.Remove(start,l);
                text=text.Insert(start,upp);
                text=text.Remove(start-8,8);
                text=text.Remove(end-8,9);
            }
        }
        Console.WriteLine(text);
    }
}